package com.project.bean;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;

import java.util.List;

@TableName("t_product")
public class ProductBean {
    @TableId(value = "pk_productId",type= IdType.AUTO)
    private Integer id;
    @TableField("p_name")
    private String name;
    @TableField("p_price")
    private Integer price;
    @TableField("p_imgPath")
    private String imgPath;
    @TableField(exist = false)
    private Integer speakNum;
    @TableField(exist = false)
    private List<SpeakBean> speakList;

    public List<SpeakBean> getSpeakList() {
        return speakList;
    }

    public void setSpeakList(List<SpeakBean> speakList) {
        this.speakList = speakList;
    }

    public Integer getSpeakNum() {
        return speakNum;
    }

    public void setSpeakNum(Integer speakNum) {
        this.speakNum = speakNum;
    }

    public Integer getId() {
        return id;
    }

    public void setId(Integer id) {
        this.id = id;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public Integer getPrice() {
        return price;
    }

    public void setPrice(Integer price) {
        this.price = price;
    }

    public String getImgPath() {
        return imgPath;
    }

    public void setImgPath(String imgPath) {
        this.imgPath = imgPath;
    }

    @Override
    public String toString() {
        return "ProductBean{" +
                "id=" + id +
                ", name='" + name + '\'' +
                ", price=" + price +
                ", imgPath='" + imgPath + '\'' +
                ", speakNum=" + speakNum +
                ", speakList=" + speakList +
                '}';
    }
}
